/**
 * 18张牌，每张牌正反各有一个数字
 * 每一次可取走两张牌，要么正面相同要么背面相同
 * 不能取者告负，问胜负
 * 博弈论加状压DP
 * O(N^2 * 2^N)
 */
#include <bits/stdc++.h>
#include <bits/extc++.h>
using namespace std;

using llt = long long;
using vi = vector<int>;
using vll = vector<llt>;

template<typename T>
istream & operator >> (istream & is, vector<T> & v){
    for(auto & i : v) is >> i;
    return is;
}

template<typename T>
void input(vector<T> & v, int n){
    v.assign(n + 1, {});
    for(int i=1;i<=n;++i) cin >> v[i];
    return;
}


int N;
vector<pair<int, int>> P;
vector<int> D;

int dfs(int status){
    if(-1 != D[status]) return D[status];

    auto & d = D[status];
    for(int i=0;i<N;++i){
        if((1 << i) & status){
            for(int j=i+1;j<N;++j){
                if((1 << j) & status){
                    if(P[i].first == P[j].first or P[i].second == P[j].second){
                        auto bmp = dfs(status ^ (1 << i) ^ (1 << j));
                        if(0 == bmp) return d = 1;
                    }
                }
            }
        }
    }
    return d = 0;
}

string proc(){
    D.assign(1<<N, -1);
    D[0] = 0;
    auto t = dfs((1<<N) - 1);
    return t ? "Takahashi" : "Aoki";
}

void work(){
    cin >> N;
    P.assign(N, {});
    for(auto & i : P) cin >> i.first >> i.second;
    cout << proc() << "\n";
    return; 
}

int main(){
#ifndef ONLINE_JUDGE
    freopen("z.txt", "r", stdin);
#endif
    ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
    int nofkase = 1;
    // cin >> nofkase;
    while(nofkase--) work();
    return 0;
}